<%@ Page Language="C#" AutoEventWireup="true" CodeFile="FormViewPage.aspx.cs" Inherits="FormViewPage" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
    <title>Untitled Page</title>
</head>
<body>
    <form id="form1" runat="server">
    <div>
        <asp:SqlDataSource ID="SqlDataSource1" runat="server" ConnectionString="<%$ ConnectionStrings:RecruitVietnamDbConnectionString %>"
            SelectCommand="SELECT [RecruiterID], [Email], [CompanyName], [EnglishName], [OpenDate], [ContactName], [Address], [ProvinceID], [Phone], [Fax], [LastLogin] FROM [tblRCAccounts]">
        </asp:SqlDataSource>
    
    </div>
        <asp:FormView ID="FormView1" runat="server" DataSourceID="SqlDataSource1" AllowPaging="True" DataKeyNames="RecruiterID" Height="85px" Width="464px">
            <ItemTemplate>
                <table style="width: 350px">
                    <tr>
                        <td style="width: 110px">
                            <asp:Label ID="Label2" runat="server" Text="RecruiterID" Width="107px"></asp:Label></td>
                        <td style="width: 12px">
                        </td>
                        <td>
                            <asp:Label ID="Label1" runat="server" Text='<%# Eval("RecruiterID", "{0}") %>' Width="228px"></asp:Label></td>
                    </tr>
                    <tr>
                        <td style="width: 110px">
                            <asp:Label ID="Label3" runat="server" Text="Email" Width="106px"></asp:Label></td>
                        <td style="width: 12px">
                        </td>
                        <td>
                            <asp:Label ID="Label6" runat="server" Text='<%# Eval("Email", "{0}") %>' Width="231px"></asp:Label></td>
                    </tr>
                    <tr>
                        <td style="width: 110px">
                            <asp:Label ID="Label5" runat="server" Text="Company Name" Width="104px"></asp:Label></td>
                        <td style="width: 12px">
                        </td>
                        <td>
                            <asp:Label ID="Label8" runat="server" Text='<%# Eval("ContactName", "{0}") %>' Width="231px"></asp:Label></td>
                    </tr>
                    <tr>
                        <td style="width: 110px">
                            <asp:Label ID="Label7" runat="server" Text="Contact Name" Width="104px"></asp:Label></td>
                        <td style="width: 12px">
                        </td>
                        <td>
                            <asp:Label ID="Label4" runat="server" Text='<%# Eval("Email", "{0}") %>' Width="231px"></asp:Label></td>
                    </tr>
                    <tr>
                        <td style="width: 110px">
                            <asp:Label ID="Label10" runat="server" Text="Phone" Width="104px"></asp:Label></td>
                        <td style="width: 12px">
                        </td>
                        <td>
                            <asp:Label ID="Label12" runat="server" Text='<%# Bind("Phone", "{0}") %>' Width="231px"></asp:Label></td>
                    </tr>
                    <tr>
                        <td style="width: 110px">
                            <asp:Label ID="Label11" runat="server" Text="Address" Width="104px"></asp:Label></td>
                        <td style="width: 12px">
                        </td>
                        <td>
                            <asp:Label ID="Label13" runat="server" Text='<%# Bind("Address", "{0}") %>' Width="231px"></asp:Label></td>
                    </tr>
                </table>
                <br />
                <asp:Button ID="Button1" runat="server" OnClick="Button1_Click" Text="Print" Width="68px" />
            </ItemTemplate>
            <EditItemTemplate>
                <table style="width: 350px">
                    <tr>
                        <td style="width: 110px">
                            <asp:Label ID="Label2" runat="server" Text="RecruiterID" Width="107px"></asp:Label></td>
                        <td style="width: 12px">
                        </td>
                        <td>
                            <asp:Label ID="Label14" runat="server" Text='<%# Eval("RecruiterID") %>' Width="195px"></asp:Label></td>
                    </tr>
                    <tr>
                        <td style="width: 110px">
                            <asp:Label ID="Label3" runat="server" Text="Email" Width="106px"></asp:Label></td>
                        <td style="width: 12px">
                        </td>
                        <td>
                            <asp:TextBox ID="TextBox1" runat="server" Text='<%# Bind("Email") %>' Width="203px"></asp:TextBox></td>
                    </tr>
                    <tr>
                        <td style="width: 110px; height: 21px">
                            <asp:Label ID="Label5" runat="server" Text="Company Name" Width="104px"></asp:Label></td>
                        <td style="width: 12px; height: 21px">
                        </td>
                        <td style="height: 21px">
                            <asp:TextBox ID="TextBox2" runat="server" Text='<%# Bind("CompanyName") %>' Width="203px"></asp:TextBox></td>
                    </tr>
                    <tr>
                        <td style="width: 110px">
                            <asp:Label ID="Label7" runat="server" Text="Contact Name" Width="104px"></asp:Label></td>
                        <td style="width: 12px">
                        </td>
                        <td>
                            <asp:TextBox ID="TextBox3" runat="server" Text='<%# Bind("ContactName") %>' Width="203px"></asp:TextBox></td>
                    </tr>
                    <tr>
                        <td style="width: 110px">
                            <asp:Label ID="Label10" runat="server" Text="Phone" Width="104px"></asp:Label></td>
                        <td style="width: 12px">
                        </td>
                        <td>
                            <asp:TextBox ID="TextBox4" runat="server" Text='<%# Bind("Address") %>' Width="203px"></asp:TextBox></td>
                    </tr>
                    <tr>
                        <td style="width: 110px">
                            <asp:Label ID="Label11" runat="server" Text="Address" Width="104px"></asp:Label></td>
                        <td style="width: 12px">
                        </td>
                        <td>
                            <asp:TextBox ID="TextBox5" runat="server" Text='<%# Bind("Phone") %>' Width="203px"></asp:TextBox></td>
                    </tr>
                </table>
                <br />
                <asp:Button ID="Button2" runat="server" OnClick="Button2_Click" Text="Update" Width="68px" />
            </EditItemTemplate>
            <InsertItemTemplate>
                <table style="width: 350px">
                    <tr>
                        <td style="width: 110px">
                            <asp:Label ID="Label3" runat="server" Text="Email" Width="106px"></asp:Label></td>
                        <td style="width: 12px">
                        </td>
                        <td>
                            <asp:TextBox ID="TextBox1" runat="server" Text='<%# Bind("Email") %>' Width="203px"></asp:TextBox></td>
                    </tr>
                    <tr>
                        <td style="width: 110px; height: 21px">
                            <asp:Label ID="Label5" runat="server" Text="Company Name" Width="104px"></asp:Label></td>
                        <td style="width: 12px; height: 21px">
                        </td>
                        <td style="height: 21px">
                            <asp:TextBox ID="TextBox2" runat="server" Text='<%# Bind("CompanyName") %>' Width="203px"></asp:TextBox></td>
                    </tr>
                    <tr>
                        <td style="width: 110px">
                            <asp:Label ID="Label7" runat="server" Text="Contact Name" Width="104px"></asp:Label></td>
                        <td style="width: 12px">
                        </td>
                        <td>
                            <asp:TextBox ID="TextBox3" runat="server" Text='<%# Bind("ContactName") %>' Width="203px"></asp:TextBox></td>
                    </tr>
                    <tr>
                        <td style="width: 110px">
                            <asp:Label ID="Label10" runat="server" Text="Phone" Width="104px"></asp:Label></td>
                        <td style="width: 12px">
                        </td>
                        <td>
                            <asp:TextBox ID="TextBox4" runat="server" Text='<%# Bind("Address") %>' Width="203px"></asp:TextBox></td>
                    </tr>
                    <tr>
                        <td style="width: 110px">
                            <asp:Label ID="Label11" runat="server" Text="Address" Width="104px"></asp:Label></td>
                        <td style="width: 12px">
                        </td>
                        <td>
                            <asp:TextBox ID="TextBox5" runat="server" Text='<%# Bind("Phone") %>' Width="203px"></asp:TextBox></td>
                    </tr>
                    <tr>
                        <td style="width: 110px">
                            Province</td>
                        <td style="width: 12px">
                        </td>
                        <td>
                            <asp:DropDownList ID="DropDownList1" runat="server" DataSourceID="SqlDataSource2"
                                DataTextField="ProvinceName" DataValueField="ProvinceID">
                            </asp:DropDownList><asp:SqlDataSource ID="SqlDataSource2" runat="server" ConnectionString="<%$ ConnectionStrings:RecruitVietnamDbConnectionString %>"
                                SelectCommand="SELECT [ProvinceID], [ProvinceName] FROM [tblProvinces]"></asp:SqlDataSource>
                        </td>
                    </tr>
                </table>
                <br />
                <asp:Button ID="Button2" runat="server" OnClick="Button2_Click" Text="Save" Width="68px" />
            </InsertItemTemplate>
            <HeaderTemplate>
                <asp:Label ID="Label9" runat="server" Font-Bold="True" Text="Recruiter Account" Width="282px"></asp:Label>
            </HeaderTemplate>
        </asp:FormView>
        <br />
        &nbsp;
    </form>
</body>
</html>
